package com.cty.dao.impl;

import com.cty.dao.JedisClusterDao;
import org.springframework.stereotype.Repository;
import redis.clients.jedis.JedisCluster;

import javax.annotation.Resource;

/**
 * @Auther: cty
 * @Date: 2020/4/11 19:20
 * @Description:
 * @version: 1.0
 */
@Repository
public class JedisClusterDaoImpl implements JedisClusterDao {
    @Resource
    private JedisCluster jedisClients;

    @Override
    public Boolean exists(String key) {
        return jedisClients.exists(key);
    }

    @Override
    public String get(String key) {
        return jedisClients.get(key);
    }

    @Override
    public String set(String key, String value) {
        return jedisClients.set(key, value);
    }
}
